<template>
  <section v-if="!!device.trackList">
    <div v-for="(item, index) in device.trackList"
         :key="index"
         class="repair-track-wrap">
      <div v-if="transportStatus.includes(item.transportType)">{{item.trackNo}}</div>
      <div v-else>{{item.deviceNo}}</div>
    </div>
  </section>
</template>

<script>
export default {
  name: 'RepairTrack',
  props: {
    row: {
      type: Object,
      default: () => { }
    }
  },
  data () {
    return {}
  },
  computed: {
    device () {
      return this.row.device
    },
    transportStatus () {
      return [1, 2, 3]
    }
  }
}
</script>

<style scoped>
.display {
  /*主要复制这三行，基本就有效果，没有效果的话，那得设置具体宽度*/
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
</style>